* Estimate Spatial Mismatch models for Appendix

* mean dependent variable
sum qtr_hire_`dep'_`suf' if qtr==8
local meandep=r(mean)

gen qtr2_hire_`dep'_`suf'=qtr_hire_`dep'_`suf'+0.5
gen qtrL_hire_`dep'_`suf'=log(qtr2_hire_`dep'_`suf')
replace qtrL_hire_`dep'_`suf'=-0.693 if qtr2_hire_`dep'_`suf'==0.5
replace qtrL_hire_`dep'_`suf'=2.2513 if qtr2_hire_`dep'_`suf'==9.5

* Table F2, Model 1: job accessibility with tau=10
* ratio, MAIN, access, worker, neighborhood, 10 minutes
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predfeas_all_10"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox'") ///
  ctitle("tob_awngh_10min") addstat("Mean Dep Var",`meandep') onecol dec(3) replace

* Table F2, Model 2: job accessibility with tau=5
* ratio, MAIN, access, worker, neighborhood, 5 minutes
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predfeas_all_5"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox'") ///
  ctitle("tob_awngh_5min") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* Table F2, Model 3: job accessibility with tau=15
* ratio, MAIN, access, worker, neighborhood, 15 minutes
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predfeas_all_15"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox'") ///
  ctitle("tob_awngh_15min") addstat("Mean Dep Var",`meandep') onecol dec(3) append

tabstat rel_jo rel_cs ratio_predfeas_all16_10, statistics(min p10 p25 p50 p75 p90 max) columns(statistics) format(%5.3g)

* Table F2, Model 4: Job accessibility with Census 2000 labor force
* ratio, access, worker, neighborhood - population 16 up in labor force (Census)
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predfeas_all16_10"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("tob_lab16up") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* Table F2, Model 5: Job accessibility with no earnings limit
* ratio, earnings all jo and cs
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predfeas_eall_`lim'"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("tob_eall") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* ratio, access, worker, neighborhood - relative JO
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="rel_jo"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8, vce(cluster fety) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("tob_rel_jo") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* ratio, access, worker, neighborhood - relative JO, CS
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="rel_jo rel_cs"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8, vce(cluster fety) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("tob_rel_jocs") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* Table F2, Model 6: Job accessibility for 3 miles of travel
* ratio, MAIN, access, worker, neighborhood, distance 3 miles
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_dist_all_3"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox'") ///
  ctitle("tob_3miles") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* Transit feasibility and likelihood  *****************************************

tabulate stmet_name transit_feas
tabulate stmet_name if transit_feas==1
tabulate stmet_name if transit_feas==0

* Table F2, Model 7: Job accessibility for automobile travel time
* ratio, MAIN, access, worker, neighborhood, 10 minutes, auto
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_auto_all_`lim'"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox'") ///
  ctitle("tob_auto") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* ratio, MAIN, access, worker, neighborhood - no transit, all access
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_auto_all_`lim'"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & transit_feas==0, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("trannone") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* ratio, MAIN, access, worker, neighborhood - no transit, all access
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predfeas_all_`lim'"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & transit_feas==0, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("trannone") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* ratio, MAIN, access, worker, neighborhood - no transit, separate access
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predauto_all_`lim' ratio_predtran_all_`lim'"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & transit_feas==0, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("trannone") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* Table F2, Model 8: Job accessibility for automobile travel time
* ratio, MAIN, access, worker, neighborhood - has transit, all access
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_auto_all_`lim'"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & transit_feas==1, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("transome") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* Table F2, Model 9: Job accessibility
* ratio, MAIN, access, worker, neighborhood - has transit, all access
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predfeas_all_`lim'"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & transit_feas==1, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("transome") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* Table F2, Model 10: Job accessibility for auto component, Job accessibility for transit component
* ratio, MAIN, access, worker, neighborhood - has transit, separate access
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predauto_all_`lim' ratio_predtran_all_`lim'"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & transit_feas==1, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("transome") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* median likelihood 0.pau
tabstat pauto ptran, statistics(n min p10 p25 p50 p75 p90 max) columns(statistics) format(%5.3g)
tabstat pauto ptran if transit_feas==1, statistics(n min p10 p25 p50 p75 p90 max) columns(statistics) format(%5.3g)
* unconditional median
local pau="964"
* conditional median
local pau_cond="937"
display "Median liklihood to have auto is 0.`pau'"

tabulate stmet_name if transit_feas==1 & pauto>=0.`pau'
tabulate stmet_name if transit_feas==1 & pauto<0.`pau'

* ratio, MAIN, access, worker, neighborhood - has transit, unlikely to use transit, all access
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_auto_all_`lim'"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & transit_feas==1 & pauto>=0.`pau', vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("transomeno") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* ratio, MAIN, access, worker, neighborhood - has transit, unlikely to use transit, all access
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predfeas_all_`lim'"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & transit_feas==1 & pauto>=0.`pau', vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("transomeno") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* ratio, MAIN, access, worker, neighborhood - has transit, unlikely to use transit, separate access
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predauto_all_`lim' ratio_predtran_all_`lim'"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & transit_feas==1 & pauto>=0.`pau', vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("transomeno") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* Table F2, Model 11: Job accessibility for automobile travel time
* ratio, MAIN, access, worker, neighborhood - has transit, likely to use transit, all access
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_auto_all_`lim'"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & transit_feas==1 & pauto<0.`pau', vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("transomeuse") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* Table F2, Model 12: Job accessibility
* ratio, MAIN, access, worker, neighborhood - has transit, likely to use transit, all access
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predfeas_all_`lim'"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & transit_feas==1 & pauto<0.`pau', vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("transomeuse") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* Table F2, Model 13: Job accessibility for auto component, Job accessibility for transit component
* ratio, MAIN, access, worker, neighborhood - has transit, likely to use transit, separate access
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predauto_all_`lim' ratio_predtran_all_`lim'"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & transit_feas==1 & pauto<0.`pau', vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("transomeuse") addstat("Mean Dep Var",`meandep') onecol dec(3) append


* Other subgroups ****************************************************

* ratio, central city
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predfeas_all_`lim'"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & met_central==1 & central_tract==1, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("zone:cent") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* ratio, middle zone
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predfeas_all_`lim'"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & met_central==1 & central_tract==0, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("zone:mid") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* ratio, outer zone
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predfeas_all_`lim'"
local control_output="`contstand'"
local control_absorb="femy_fe*"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & met_central==0 & central_tract==0, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("zone:out") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* list of metros
levelsof stmet_name, local(stmet_lev)

* produce for each metropolitan area
foreach stmet in `stmet_lev' {

* mean dependent variable
sum qtr_hire_`dep'_`suf' if qtr==8 & stmet_name=="`stmet'"
local meandep=r(mean)

* ratio, metro only
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predfeas_all_`lim'"
local control_output="`contstand'"
local control_absorb="`control_year'"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & stmet_name=="`stmet'", vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("stmet:`stmet'") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* ratio, metro only
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predfeas_all_`lim'"
local control_output="`contstand'"
local control_absorb="`control_year'"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & stmet_name=="`stmet'" & transit_feas==1, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("stmet:`stmet'") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* ratio, metro only
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_predauto_all_`lim' ratio_predtran_all_`lim'"
local control_output="`contstand'"
local control_absorb="`control_year'"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & stmet_name=="`stmet'" & transit_feas==1, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("stmet:`stmet'") addstat("Mean Dep Var",`meandep') onecol dec(3) append

* ratio, metro only
local depvar="qtrL_hire_`dep'_`suf'"
local smvar="ratio_tran_all_`lim'"
local control_output="`contstand'"
local control_absorb="`control_year'"
tobit `depvar' `smvar' `control_output' `control_sec' `control_seas' `control_absorb' ///
  if qtr==8 & stmet_name=="`stmet'" & transit_feas==1, vce(cluster puma5) ll(-0.693) ul(2.251)
outreg2 `depvar' `smvar' `control_output' `control_sec' `control_seas' ///
  using `vnum'_`vers'_`dep'_`suf'_`prox'_`lim'.xls, ///
  excel title("tobit dependent:`dep' sufficient:`suf' proximity:`prox' limit:`lim'") ///
  ctitle("stmet:`stmet'") addstat("Mean Dep Var",`meandep') onecol dec(3) append

}
